package com.mc.model;

import java.util.Date;

import javax.swing.text.StyleContext.SmallAttributeSet;

public class newsandbulletin {
	private Integer id;

	private String title;

	private String publishDate;

	private User author;

	private String bn;

	private String belong;

	private String content;

	private String url;

	private boolean isindex;

	public final static String DJ_NEWS = "0010";
	public final static String COMMON_NEWS = "0001";
	public final static String STUDENT_NEWS = "0100";
	public final static String ZSJY_NEWS = "1000";
	
	public final static String DJ_BULLETIN = "010";
	public final static String COMMON_BULLETIN = "001";
	public final static String STUDENT_BULLETIN = "100";
	public final static String ZSJY_BULLETIN = "1000";

	public String getUrl() {
		return url;
	}

	public void setUrl(String url) {
		this.url = url;
	}

	public boolean isIsindex() {
		return isindex;
	}

	public void setIsindex(boolean isindex) {
		this.isindex = isindex;
	}


  
    
    private int index;
    
   

	public int getIndex() {
		return index;
	}

	public void setIndex(int index) {
		this.index = index;
	}



	public Integer getId() {
		return id;
	}


	public void setId(Integer id) {
		this.id = id;
	}

	public String getTitle() {
		return title;
	}

	public void setTitle(String title) {
		this.title = title == null ? null : title.trim();
	}

	public String getPublishDate() {
		return publishDate.split(" ")[0];
	}

	public void setPublishDate(String publishDate) {
		this.publishDate = publishDate;
	}

	public User getAuthor() {
		return author;
	}

	public void setAuthor(User author) {
		this.author = author;
	}

	public String getBn() {
		return bn;
	}

	public void setBn(String bn) {
		this.bn = bn == null ? null : bn.trim();
	}

	public String getBelong() {
		return belong;
	}

	public void setBelong(String belong) {
		this.belong = belong;
	}

	public String getContent() {
		return content;
	}

	public void setContent(String content) {
		this.content = content == null ? null : content.trim();
	}

	@Override
	public String toString() {
		return "newsandbulletin [id=" + id + ", title=" + title
				+ ", publishDate=" + publishDate + ", author=" + author
				+ ", bn=" + bn + ", belong=" + belong + ", content=" + content
				+ ", url=" + url + ", index=" + index + "]";
	}


	
    
 
}